package com.api.shopapi.service.impl;

import com.api.shopapi.entity.UserPrinter;
import com.api.shopapi.mapper.UserPrinterMapper;
import com.api.shopapi.service.UserPrinterService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service("UserPrinterServiceImplOne")
public class UserPrinterServiceImpl implements UserPrinterService {

    @Autowired
    private UserPrinterMapper userPrinterMapper;

    @Override
    public
    int insert(UserPrinter userPrinter){
        return userPrinterMapper.insert(userPrinter);
    }
    @Override
    public
    int delete(String userPrinterCode){
        return userPrinterMapper.delete(userPrinterCode);
    }
    @Override
    public
    int update(UserPrinter userPrinter){
        return userPrinterMapper.update(userPrinter);
    }
    @Override
    public
    UserPrinter getByUserPrinterCode(String userPrinterCode){
        return userPrinterMapper.getByUserPrinterCode(userPrinterCode);
    }
    @Override
    public
    UserPrinter getByUserCode(String userCode){
        return userPrinterMapper.getByUserCode(userCode);
    }

}
